<?php defined('BASEPATH') or exit('No direct script access allowed.'); ?><?php defined('BASEPATH') or exit('No permission resources.'); ?>
<form class="form-horizontal" role="form" id="validateform" name="validateform" action="<?php echo base_url('adminpanel/customer/edit')?>" >
	<div class='panel panel-default '>
		<div class='panel-heading'>
			<i class='fa fa-table'></i> 客户管理 修改信息
			<div class='panel-tools'>
				<div class='btn-group'>
					<a class="btn " href="<?php echo base_url('adminpanel/customer')?>"><span class="glyphicon glyphicon-arrow-left"></span> 返回 </a>
				</div>
			</div>
		</div>
		<div class='panel-body '>
								<fieldset>
						<legend>基本信息</legend>
													
	<div class="form-group">
				<label for="name" class="col-sm-2 control-label form-control-static">客户姓名</label>
				<div class="col-sm-9 ">
					<input type="text" name="name"  id="name"  value='<?php echo isset($data_info['name'])?$data_info['name']:'' ?>'  class="form-control validate[required]"  placeholder="请输入客户姓名" >
				</div>
			</div>
													
	<div class="form-group">
				<label for="cfrom" class="col-sm-2 control-label form-control-static">地区</label>
				<div class="col-sm-9 ">
					<input type="text" name="cfrom"  id="cfrom"  value='<?php echo isset($data_info['cfrom'])?$data_info['cfrom']:'' ?>'  class="form-control validate[required]"  placeholder="请输入地区" >
				</div>
			</div>
													
	<div class="form-group">
				<label for="address" class="col-sm-2 control-label form-control-static">详细地址</label>
				<div class="col-sm-9 ">
					<input type="text" name="address"  id="address"  value='<?php echo isset($data_info['address'])?$data_info['address']:'' ?>'  class="form-control validate[required]"  placeholder="请输入详细地址" >
				</div>
			</div>
													
	<div class="form-group">
				<label for="mobile" class="col-sm-2 control-label form-control-static">手机号码</label>
				<div class="col-sm-9 ">
					<input type="text" name="mobile"  id="mobile"   value='<?php echo isset($data_info['mobile'])?$data_info['mobile']:'' ?>'   class="form-control  validate[custom[phone]]"  placeholder="请输入手机号码" >
				</div>
			</div>
													
	<div class="form-group">
				<label for="weixin" class="col-sm-2 control-label form-control-static">微信</label>
				<div class="col-sm-9 ">
					<input type="text" name="weixin"  id="weixin"  value='<?php echo isset($data_info['weixin'])?$data_info['weixin']:'' ?>'  class="form-control validate[required]"  placeholder="请输入微信" >
				</div>
			</div>
													
	<div class="form-group">
				<label for="qq" class="col-sm-2 control-label form-control-static">QQ号</label>
				<div class="col-sm-9 ">
					<input type="number" name="qq"  id="qq"  value='<?php echo isset($data_info['qq'])?$data_info['qq']:'' ?>'   class="form-control validate[custom[integer]]" placeholder="请输入QQ号" >
				</div>
			</div>
													
	<div class="form-group">
				<label for="email" class="col-sm-2 control-label form-control-static">电子邮件</label>
				<div class="col-sm-9 ">
					<input type="email" name="email"  id="email"   value='<?php echo isset($data_info['email'])?$data_info['email']:'' ?>'  class="form-control  validate[custom[email]]"  placeholder="请输入电子邮件" >
				</div>
			</div>
													
	<div class="form-group">
				<label for="status" class="col-sm-2 control-label form-control-static">状态</label>
				<div class="col-sm-9 ">
					<select class="form-control  validate[required]"  name="status"  id="status">
				<option value="">==请选择==</option>
								<option value='正常' <?php if(isset($data_info['status'])&&($data_info['status']=='正常')) { ?> selected="selected" <?php } ?>            >正常</option>
				<option value='删除' <?php if(isset($data_info['status'])&&($data_info['status']=='删除')) { ?> selected="selected" <?php } ?>            >删除</option>
</select>
				</div>
			</div>
													
	<div class="form-group">
				<label for="level" class="col-sm-2 control-label form-control-static">等级</label>
				<div class="col-sm-9 ">
					<select class="form-control  validate[required]"  name="level"  id="level">
				<option value="">==请选择==</option>
								<option value='普通' <?php if(isset($data_info['level'])&&($data_info['level']=='普通')) { ?> selected="selected" <?php } ?>            >普通</option>
				<option value='潜在' <?php if(isset($data_info['level'])&&($data_info['level']=='潜在')) { ?> selected="selected" <?php } ?>            >潜在</option>
				<option value='高意向' <?php if(isset($data_info['level'])&&($data_info['level']=='高意向')) { ?> selected="selected" <?php } ?>            >高意向</option>
				<option value='产品客户' <?php if(isset($data_info['level'])&&($data_info['level']=='产品客户')) { ?> selected="selected" <?php } ?>            >产品客户</option>
				<option value='事业伙伴' <?php if(isset($data_info['level'])&&($data_info['level']=='事业伙伴')) { ?> selected="selected" <?php } ?>            >事业伙伴</option>
</select>
				</div>
			</div>
													
	<div class="form-group">
				<label for="notes" class="col-sm-2 control-label form-control-static">备注</label>
				<div class="col-sm-9 ">
					<textarea name="notes"  id="notes"  cols="45" rows="5" class="form-control " placeholder="请输入备注" > <?php echo isset($data_info['notes'])?$data_info['notes']:'' ?></textarea>
				</div>
			</div>
											</fieldset>
							<div class='form-actions'>
				<button class='btn btn-primary ' type='submit' id="dosubmit">保存</button>
			</div>
</form>
			<script language="javascript" type="text/javascript">
			var is_edit =<?php echo ($is_edit)?"true":"false" ?>;
			var id =<?php echo $id;?>;

			require(['<?php echo SITE_URL?>scripts/common.js'], function (common) {
		        require(['<?php echo SITE_URL?>scripts/adminpanel/customer/edit.js']);
		    });
		</script>
	
	